/*---------------------------------------------------------

  Space Is The Place Gamemode

---------------------------------------------------------*/

--Two teams:
--	FSA (Free Space Authority), GMC (Galactic Mining Corporation)
-- Spawnpoints[Map][Team][point number]

function SITP_FSA ( ply )
	if SERVER then
		if(ply.sitp_team == ply.sitp_spacetype or ply.sitp_spacetype == "all") then
			ply:SetNetworkedString("sitp_team", "fsa")
			ply:Spawn()
		else
			ply:ChatPrint( "You can only switch teams if you are on your own homeworld!" )
		end
	end
end

concommand.Add("SITP_FSA", SITP_FSA)

function SITP_Merc ( ply )
	if SERVER then
		if(ply.sitp_team == ply.sitp_spacetype or ply.sitp_spacetype == "all") then
			ply:SetNetworkedString("sitp_team", "merc")
			ply:Spawn()
		else
			ply:ChatPrint( "You can only switch teams if you are on your own homeworld!" )
		end
	end
end

concommand.Add("SITP_Merc", SITP_Merc)

function SITP_GMC ( ply )
	if SERVER then
		if(ply.sitp_team == ply.sitp_spacetype or ply.sitp_spacetype == "all") then
			ply:SetNetworkedString("sitp_team", "gmc")
			ply:Spawn()
		else
			ply:ChatPrint( "You can only switch teams if you are on your own homeworld!" )
		end
	end
end

concommand.Add("SITP_GMC", SITP_GMC)